import '../../style/home.css'
import React from 'react'
import ReactDOM from 'react-dom'
import { compose } from 'redux';
import { connect } from 'react-redux';
import { Redirect, History, Link, browserHistory } from 'react-router-dom'

class Login extends React.Component {

    constructor(props) {
        super(props)
    }
    handleSubmit(event) {
        event.preventDefault()
        return this.props.history.push('/graph/aaaaa')
    }
    render() {
        return (
            <div>
                <form onSubmit={this.handleSubmit.bind(this)}>
                    <input type="text" placeholder="userName" />
                    <input type="text" placeholder="repo" />
                    <button type="submit">Go</button>
                </form>
            </div>
        )
    }
}

export default compose(
    connect(state =>{console.log(state );return state.login;}),
)(Login);
